package jp.co.piratealliance.pirateAllianceWeb.dao.goods;

import java.util.List;
import java.util.Map;

import jp.co.piratealliance.pirateAllianceWeb.dto.com.AreaInfoDto;
import jp.co.piratealliance.pirateAllianceWeb.dto.goods.GoodsInfoDto;
import jp.co.piratealliance.pirateAllianceWeb.dto.goods.PayTypeInfoDto;
import jp.co.piratealliance.pirateAllianceWeb.dto.goods.ResourceTypeInfoDto;


/**
 * copyright   pirate alliance team 2014
 * @author     lunxing
 *
 */

public interface GoodsDao {

	public List<GoodsInfoDto> selectGoods(Map<String,Object> param);

	public GoodsInfoDto selectGoodsByOrderId(Map<String,Object> param);

	public List<AreaInfoDto> selectAreaByLevel(Map<String,Object> param);

	public List<String> selectAreaIDByName(String param);

	public AreaInfoDto selectAreaByAreaIDAndLanguageId(Map<String,Object> param);

	public List<ResourceTypeInfoDto> selectAllResourceType();

	public List<ResourceTypeInfoDto> selectGoodsResourceTypeByGoodsId(String param);

	public void insertGoodsOfResourceInfo(GoodsInfoDto goodsInfoForResource);

	public void insertResourceLanguageInfo(GoodsInfoDto goodsInfoForResource);

	public List<GoodsInfoDto> selectCurrencyUnitId();

	public List<GoodsInfoDto> selectGoodsInfo();

	public void updateResourceInfo(GoodsInfoDto goodsInfoForResource);

	public void updateGoodsOfResourceInfo(GoodsInfoDto goodsInfoForResource);

	public void updateResourceLanguageInfo(GoodsInfoDto goodsInfoForResource);

	//ユーザーIDによって　全部商品情報を検索する
	public List<GoodsInfoDto> selectGoodsListByUserId(String param);
	public List<GoodsInfoDto> selectResorceGoodsListByUserId(String param);

	//商品登録画面に、選択した商品情報を検索する
	public List<GoodsInfoDto> selectGoodsListByGoodsId(String param);
	public List<GoodsInfoDto> selectGoodsListByGoodsIdLanguageId(Map<String,Object> param);


	//商品Insert
	public void insertGoodsBaseInfo(GoodsInfoDto goodsBaseInfo);

	//商品詳細Insert
	public void insertGoodsLanguageInfo(GoodsInfoDto goodsBaseInfo);

	//商品詳細Update
	public void updateGoodsLanguageInfo(GoodsInfoDto goodsBaseInfo);

	public void updateGoodsBaseInfo(GoodsInfoDto goodsBaseInfo);

	//商品情報存在性判定
	public int checkGoodsByGoodsIdAndLanguage(Map<String,Object> param);

	public List<GoodsInfoDto> selectResourceListByGoodsId(Map<String,Object> param);

	public List<GoodsInfoDto> selectHomePageGoods();

	public List<ResourceTypeInfoDto> selectResourceListInfo(int resource_type_id);

	//插入商品と資源商品分類関連表
	public void insertGoodsResourceTypeInfo(GoodsInfoDto goodsInfoForResource);
	
	//删除商品と資源商品分類関連表
	public void deleteGoodsResourceTypeInfo(String goodsId);

	//支付方法列表
	public List<PayTypeInfoDto> selectPayTypeInfo();


}
